package com.songlanyun.modules.offlinegoods.service;

import com.songlanyun.common.drive.IBaseService;
import com.songlanyun.modules.offlinegoods.entity.OfflineGoods;
import com.songlanyun.modules.offlinegoods.model.dto.OfflineGoodsDTO;

/**
 * 线下商品
 *
 * @author lijiahe
 * @date 2023-02-11
 */
public interface OfflineGoodsService extends IBaseService<Long, OfflineGoods> {

    /**
     * 线下商品详情
     *
     * @param id
     *            主键id
     * @param tw
     * @return
     */
    OfflineGoods loadOfflineGoodsById(Long id, Boolean tw);

    void saveDto(OfflineGoodsDTO dto);

    void updateDto(Long shopId, OfflineGoodsDTO dto);

    void deleteWithValidById(Long id, Long shopId, Boolean isValid);

    /**
     * 上下架
     *
     * @param id
     * @param shopId
     */
    void upOrOffShelf(Long id, Long shopId);
}
